// Box Klasse

#pragma once

#include "../../Base/DxDevice.h"
#include "../../Base/GameEngine.h"
#include "../../Forest/TreeNode.h"
#include "../../Base/vertex.h"
class NxActor;

class Box: public TreeNode
{
public:
	Box(const MeshDesc& mDesc, const D3DXVECTOR3& pos, float width, float length, float height);
	virtual ~Box();

	void Draw();
	void Init(const MeshDesc& mDesc);
	const ID3D10ShaderResourceView* GetTexture() const;
	const ID3D10ShaderResourceView* GetNormalMap() const;
	const ID3D10ShaderResourceView* GetSpecularMap() const;

private:

	D3DXVECTOR3 m_Pos;
	float m_Width, m_Length, m_Height;
	ID3D10ShaderResourceView* m_Texture, *m_NormalMap, *m_SpecMap;
	AABB m_BoundingBox;

	vector<Vertex> m_VertexList;
	vector<DWORD> m_IndexList;
	tstring m_TextureFile, m_NormalTex, m_SpecTex;

	ID3DX10Mesh* m_Mesh;

	Box(const Box &t);
	Box& operator= (const Box &t);
};